<?php


?>
<script type="text/javascript">
function plusmoney(userid)
{
	 $.ajax({
     	
     	
			url: "viewmemberdetail.php" ,
			type:'POST',
			data:"fundmoney=1&userid="+userid+"&pass="+$("#pass").val()+"&amount="+$("#plusmoney").val(),
			cache: false,
			success: function(j){
			$("#freshcvvfundmoney").html(j);
		  	}
		});
		 
}
function active(userid)
{
	 $.ajax({
     	
     	
			url: "active.php" ,
			type:'GET',
			data:"userid="+userid,
			cache: false,
			success: function(j){
			$("#freshcvvfundmoney").html(j);
		  	}
		});
		 
}
</script>
<table border="1" width="100%">
<tr class="classmenu">
<td colspan="4">
Member Detail
</td>
</tr>
<tr class="classtopmenu">
<td>
User: <?php echo $UserName; ?>
</td>
<td>
Số Tiền Đã Nạp: <?php echo $Deposit; ?>
</td>
<td>
Ngày Nạp Cuối Cùng: <?php 

if(!empty($DateLastPayment))
{
	echo $DateLastPayment; 
}
else 
{
	echo "0";
}
?>
</td>
<td>
Balance <?php echo $GetDeposit[0]['money'];?>
</td>
</tr>
<tr>
<td colspan=3 >
<?php if($IsActive==1)
{
	echo "Status: Active";
}
else 
{
	echo "Status: InAcctive";
	?>
	<a href="#" onclick="javascript:active(<?php echo $UserId;?>)" >Click To Active</a>
	<?php 
}
?>
</td>
</tr>
<tr>
<td colspan="2">

<a href="../orderhistory.php?userid=<?php echo $UserId;?>" >View Order History</a>
</td>
<td>

<a href="../paymenthistory.php?userid=<?php echo $UserId;?>" >View Payment History</a>
</td>
</tr>
<tr class="classtopmenu">
<td>
Plus Money: <input id="plusmoney" name="plusmoney" type="text" >

</td>
<td >
Pass: <input id="pass" name="pass" type="password" >
</td>
<td >
<input name="submit" type="Submit" onclick="javascript:plusmoney(<?php echo $UserId;?>)" />
</td>
</tr>
</table>